package com.swf.common.exception;

import com.swf.common.exception.*;

public class CMSException extends WebException{
	private static final long serialVersionUID = 2173320075498565728L;
	
	private boolean printTraceMessage = true;
	public CMSException(String errorCode) {
		super();
		super.setErrorCode(errorCode);
	}
	
	public CMSException(String errorCode,boolean printTraceMessage){
		super();
		super.setErrorCode(errorCode);
		setPrintTraceMessage(printTraceMessage);
	}
	
	public CMSException(String errorCode, String message){
		super(message);
		super.setErrorCode(errorCode);
		super.setShowMessage(message);
	}
	public CMSException(String errorCode, String message,boolean printTraceMessage){
		super(message);
		super.setErrorCode(errorCode);
		super.setShowMessage(message);
		setPrintTraceMessage(printTraceMessage);
	}
	
	public CMSException(String errorCode,Throwable cause){
		super(cause);
		super.setErrorCode(errorCode);
	}
	public CMSException(String errorCode,Throwable cause,boolean printTraceMessage){
		super(cause);
		super.setErrorCode(errorCode);
		setPrintTraceMessage(printTraceMessage);
	}
	
	public CMSException(String errorCode,String message,Throwable cause) {
		super(message, cause);
		super.setErrorCode(errorCode);
		super.setShowMessage(message);
	}
	public CMSException(String errorCode,String message,Throwable cause,boolean printTraceMessage) {
		super(message, cause);
		super.setErrorCode(errorCode);
		super.setShowMessage(message);
		setPrintTraceMessage(printTraceMessage);
	}
	public CMSException(Throwable cause) {
		super(cause);
	}
	
	public CMSException(Throwable cause,boolean printTraceMessage) {
		super(cause);
		setPrintTraceMessage(printTraceMessage);
	}
	
	
	
	
	public boolean isPrintTraceMessage() {
		return printTraceMessage;
	}

	public void setPrintTraceMessage(boolean printTraceMessage) {
		this.printTraceMessage = printTraceMessage;
	}
	
	
	
}
